

<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
    <style>
    /* base */
    html,
    body,
    .container {
      width: 100%;
      height: 100%;
    }

    a,
    a:link,
    a:visited {
      text-decoration: none;
      color: inherit;
    }

    ul {
      list-style: none;
    }

    *,
    ::before,
    ::after {
      box-sizing: border-box;
      margin: 0;
      padding: 0;
    }

    *:focus {
      outline: 0;
    }

    .container {
      display: flex;
      padding-top: 20px;
    }

    /* Nav */
    .container .doc-nav {
      position: fixed;
      height: 100%;
      margin: 0 30px 0 40px;
      width: 280px;
    }

    .doc-nav .nav-header {
      display: flex;
      align-items: center;
      box-sizing: border-box;
      background-color: rgb(240, 241, 242);
      height: 40px;
      padding: 16px;
      font-size: 18px;
      font-weight: 500;
      color: rgb(62, 64, 66);
      cursor: pointer;
    }

    .doc-nav .nav-content {
      height: calc(100% - 40px);
      overflow-y: auto;
      color: rgb(32, 34, 36);
    }

    .doc-nav .nav-content .nav-list,
    .doc-nav .nav-content .nav-sub-list {
      line-height: 1.5rem;
    }

    .doc-nav .nav-content .nav-label {
      display: inline-block;
      position: relative;
      padding: 2px 0 2px 20px;
      margin-bottom: 4px;
    }

    .doc-nav .nav-content .nav-sub-label {
      position: relative;
      padding: 2px 0 2px 40px;
      font-size: 14px;
    }

    .doc-nav .nav-content .nav-sub-label:hover {
      text-decoration: underline;
    }

    .doc-nav .nav-content .nav-list .nav-label.group::before {
      border-bottom: 0.25rem solid transparent;
      border-left: 0.25rem solid #6e7072;
      border-right: 0;
      border-top: 0.25rem solid transparent;
      content: '';
      display: block;
      height: 0;
      left: 0.5rem;
      position: absolute;
      top: 0.625rem;
      transition: transform 0.1s linear;
      width: 0;
    }

    .doc-nav .nav-content .nav-list .nav-label.group.active::before {
      transform: rotate(90deg);
    }

    /* doc content */
    .container .doc-content {
      position: fixed;
      height: 100%;
      width: calc(100% - 80px - 40px - 30px - 240px);
      right: 0%;
      overflow-y: auto;
    }

    .doc-title {
      border-bottom: 1px solid #dcdee0;
      font-size: 22px;
      margin: 8px 0 0;
      padding-bottom: 16px;
    }

    .doc-content h3 {
      font-size: 24px;
      font-weight: 600;
      margin: 24px 0;
    }

    .doc-content h4 {
      font-size: 22px;
      font-weight: 500;
      margin: 30px 0 8px;
    }

    .doc-content h4 span {
      color: #007d9c;
    }

    .doc-content .doc-declare {
      background-color: #fafafa;
      border-radius: 5px;
      border: 1px solid #ccc;
      font-size: 14px;
      overflow-x: auto;
      padding: 10px;
      tab-size: 4;
      line-height: 20px;
    }

    .doc-content .doc-comment {
      font-size: 16px;
      margin: 16px 0;
      line-height: 24px;
      word-break: break-word;
    }
  </style>

</head>
<body>
  <div class="container">
    <div class="doc-nav">
      <a href="#Documentation" class="nav-header">Documentation</a>
      <nav class="nav-content">
        <ul class="nav-list">
          <li>
            <a href="#includes" class="nav-label">Includes</a>
             
            <ul class="nav-sub-list">

              <li>
                <a href="#tuya_cloud_com_defs.h" class="nav-sub-label">tuya_cloud_com_defs.h</a>
              </li>
      

              <li>
                <a href="#gw_intf.h" class="nav-sub-label">gw_intf.h</a>
              </li>
      
            </ul>
            
          </li>
          <li>
            <a href="#macros" class="nav-label">Macros</a>
             
            <ul class="nav-sub-list">

              <li>
                <a href="#TUYA_DEVOS_NETLINK_H" class="nav-sub-label">TUYA_DEVOS_NETLINK_H</a>
              </li>
      

              <li>
                <a href="#EVT_NETLINK_UP" class="nav-sub-label">EVT_NETLINK_UP</a>
              </li>
      

              <li>
                <a href="#EVT_NETLINK_DOWN" class="nav-sub-label">EVT_NETLINK_DOWN</a>
              </li>
      
            </ul>
            
          </li>
          <li>
            <a href="#functions" class="nav-label">Functions</a>
             
            <ul class="nav-sub-list">

              <li>
                <a href="#tuya_devos_netlink_init" class="nav-sub-label">tuya_devos_netlink_init</a>
              </li>
      

              <li>
                <a href="#tuya_devos_netlink_start" class="nav-sub-label">tuya_devos_netlink_start</a>
              </li>
      

              <li>
                <a href="#tuya_devos_netlink_stop" class="nav-sub-label">tuya_devos_netlink_stop</a>
              </li>
      

              <li>
                <a href="#tuya_devos_netlink_monitor_enable" class="nav-sub-label">tuya_devos_netlink_monitor_enable</a>
              </li>
      

              <li>
                <a href="#tuya_devos_netlink_monitor_disable" class="nav-sub-label">tuya_devos_netlink_monitor_disable</a>
              </li>
      

              <li>
                <a href="#get_base_gw_nw_status" class="nav-sub-label">get_base_gw_nw_status</a>
              </li>
      

              <li>
                <a href="#get_wired_wifi_gw_net_mode" class="nav-sub-label">get_wired_wifi_gw_net_mode</a>
              </li>
      

              <li>
                <a href="#get_wired_wifi_current_net" class="nav-sub-label">get_wired_wifi_current_net</a>
              </li>
      

              <li>
                <a href="#set_wired_wifi_current_net" class="nav-sub-label">set_wired_wifi_current_net</a>
              </li>
      

              <li>
                <a href="#get_base_gw_nw_status" class="nav-sub-label">get_base_gw_nw_status</a>
              </li>
      

              <li>
                <a href="#get_gw_nw_status" class="nav-sub-label">get_gw_nw_status</a>
              </li>
      

              <li>
                <a href="#get_wf_gw_nw_status" class="nav-sub-label">get_wf_gw_nw_status</a>
              </li>
      

              <li>
                <a href="#gw_wifi_modify_and_conn" class="nav-sub-label">gw_wifi_modify_and_conn</a>
              </li>
      

              <li>
                <a href="#gw_get_ip" class="nav-sub-label">gw_get_ip</a>
              </li>
      

              <li>
                <a href="#gw_get_mac" class="nav-sub-label">gw_get_mac</a>
              </li>
      

              <li>
                <a href="#gw_get_rssi" class="nav-sub-label">gw_get_rssi</a>
              </li>
      
            </ul>
            
          </li>
          <li>
            <a href="#vars" class="nav-label">Vars</a>
            
            <ul class="nav-sub-list">
            
            </ul>
            
          </li>
          <li>
            <a href="#consts" class="nav-label">Consts</a>
            
            <ul class="nav-sub-list">
            
            </ul>
            
          </li>
          <li>
            <a href="#types" class="nav-label">Types</a>
            
            <ul class="nav-sub-list">
            
            </ul>
            
          </li>
          <li>
            <a href="#typedefs" class="nav-label">Typedefs</a>
             
            <ul class="nav-sub-list">

              <li>
                <a href="#tuya_netlink_t;
" class="nav-sub-label">tuya_netlink_t;
</a>
              </li>
      
            </ul>
            
          </li>
        </ul>
      </nav>
    </div>
    <div class="doc-content">
      <h2 id="Documentation" class="doc-title">Documentation</h2>
      <h3 id="includes">Includes</h3>
      

      <h4 id="tuya_cloud_com_defs.h"><span>tuya_cloud_com_defs.h</span></h4>
      <pre class="doc-declare"><code>#include "tuya_cloud_com_defs.h"
</code></pre>
      <pre class="doc-comment">#include "tuya_cloud_com_defs.h"
</pre>

      <h4 id="gw_intf.h"><span>gw_intf.h</span></h4>
      <pre class="doc-declare"><code>#include "gw_intf.h"
</code></pre>
      <pre class="doc-comment">#include "gw_intf.h"
</pre>
      <h3 id="macros">Macros</h3>
      

      <h4 id="TUYA_DEVOS_NETLINK_H">Marco <span>TUYA_DEVOS_NETLINK_H</span></h4>
      <pre class="doc-declare"><code>#define TUYA_DEVOS_NETLINK_H
</code></pre>
      <pre class="doc-comment"></pre>

      <h4 id="EVT_NETLINK_UP">Marco <span>EVT_NETLINK_UP</span></h4>
      <pre class="doc-declare"><code>#define EVT_NETLINK_UP     "netlink.up" // network linkage up
</code></pre>
      <pre class="doc-comment"></pre>

      <h4 id="EVT_NETLINK_DOWN">Marco <span>EVT_NETLINK_DOWN</span></h4>
      <pre class="doc-declare"><code>#define EVT_NETLINK_DOWN   "netlink.down" // network linkage down
</code></pre>
      <pre class="doc-comment"></pre>
      <h3 id="functions">Functions</h3>
      

      <h4 id="tuya_devos_netlink_init">Func <span>tuya_devos_netlink_init</span></h4>
      <pre class="doc-declare"><code>OPERATE_RET tuya_devos_netlink_init(tuya_netlink_t *param);</code></pre>
      <pre class="doc-comment">/**
 * @brief Initialize network linkage module
 * 
 * @param[in] param Init param, see tuya_netlink_t
 * 
 * @return OPRT_OK on success. Others on error, please refer to tuya_error_code.h
 */</pre>

      <h4 id="tuya_devos_netlink_start">Func <span>tuya_devos_netlink_start</span></h4>
      <pre class="doc-declare"><code>OPERATE_RET tuya_devos_netlink_start(VOID);</code></pre>
      <pre class="doc-comment">/**
 * @brief Start network linkage module
 * 
 * @return OPRT_OK on success. Others on error, please refer to tuya_error_code.h
 */</pre>

      <h4 id="tuya_devos_netlink_stop">Func <span>tuya_devos_netlink_stop</span></h4>
      <pre class="doc-declare"><code>OPERATE_RET tuya_devos_netlink_stop(VOID);</code></pre>
      <pre class="doc-comment">/**
 * @brief Stop network linkage module
 * 
 * @return OPRT_OK on success. Others on error, please refer to tuya_error_code.h
 */</pre>

      <h4 id="tuya_devos_netlink_monitor_enable">Func <span>tuya_devos_netlink_monitor_enable</span></h4>
      <pre class="doc-declare"><code>OPERATE_RET tuya_devos_netlink_monitor_enable(VOID);</code></pre>
      <pre class="doc-comment">/**
 * @brief Enable network linkage monitor
 * 
 * @return OPRT_OK on success. Others on error, please refer to tuya_error_code.h
 */</pre>

      <h4 id="tuya_devos_netlink_monitor_disable">Func <span>tuya_devos_netlink_monitor_disable</span></h4>
      <pre class="doc-declare"><code>OPERATE_RET tuya_devos_netlink_monitor_disable(VOID);</code></pre>
      <pre class="doc-comment">/**
 * @brief Disable network linkage monitor
 * 
 * @return OPRT_OK on success. Others on error, please refer to tuya_error_code.h
 */</pre>

      <h4 id="get_base_gw_nw_status">Func <span>get_base_gw_nw_status</span></h4>
      <pre class="doc-declare"><code>OPERATE_RET get_base_gw_nw_status(OUT GW_BASE_NW_STAT_T *nw_stat);</code></pre>
      <pre class="doc-comment">/**
 * @brief Get device network linkage state
 * 
 * @param[out] nw_stat Linkage state, see GW_BASE_NW_STAT_T
 * 
 * @return OPRT_OK on success. Others on error, please refer to tuya_error_code.h
 */</pre>

      <h4 id="get_wired_wifi_gw_net_mode">Func <span>get_wired_wifi_gw_net_mode</span></h4>
      <pre class="doc-declare"><code>VOID get_wired_wifi_gw_net_mode(OUT IOT_GW_NET_TYPE_T *net_mode);</code></pre>
      <pre class="doc-comment">/**
 * @brief Get device network state
 * 
 * @param[out] nw_stat Network state, see IOT_GW_NET_TYPE_T
 * 
 * @return OPRT_OK on success. Others on error, please refer to tuya_error_code.h
 */</pre>

      <h4 id="get_wired_wifi_current_net">Func <span>get_wired_wifi_current_net</span></h4>
      <pre class="doc-declare"><code>VOID get_wired_wifi_current_net(OUT CUR_NET_STATUS_T *current_net);</code></pre>
      <pre class="doc-comment">/**
 * @brief Get network concurrent state
 * 
 * @param[out] nw_stat Concurrent state, see CUR_NET_STATUS_T
 * 
 * @return OPRT_OK on success. Others on error, please refer to tuya_error_code.h
 */</pre>

      <h4 id="set_wired_wifi_current_net">Func <span>set_wired_wifi_current_net</span></h4>
      <pre class="doc-declare"><code>VOID set_wired_wifi_current_net(IN CUR_NET_STATUS_T current_net);</code></pre>
      <pre class="doc-comment">/**
 * @brief Set network concurrent state
 * 
 * @param[in] nw_stat Concurrent state, see CUR_NET_STATUS_T
 * 
 * @return OPRT_OK on success. Others on error, please refer to tuya_error_code.h
 */</pre>

      <h4 id="get_base_gw_nw_status">Func <span>get_base_gw_nw_status</span></h4>
      <pre class="doc-declare"><code>OPERATE_RET get_base_gw_nw_status(OUT GW_BASE_NW_STAT_T *nw_stat);</code></pre>
      <pre class="doc-comment">/**
 * @brief Get device network linkage state
 * 
 * @param[out] nw_stat Linkage state, see GW_BASE_NW_STAT_T
 * 
 * @return OPRT_OK on success. Others on error, please refer to tuya_error_code.h
 */</pre>

      <h4 id="get_gw_nw_status">Func <span>get_gw_nw_status</span></h4>
      <pre class="doc-declare"><code>GW_NW_STAT_T get_gw_nw_status(VOID);</code></pre>
      <pre class="doc-comment">/**
 * @brief Get device network linkage state
 * 
 * @param[out] nw_stat Linkage state, see GW_NW_STAT_T
 * 
 * @return OPRT_OK on success. Others on error, please refer to tuya_error_code.h
 */</pre>

      <h4 id="get_wf_gw_nw_status">Func <span>get_wf_gw_nw_status</span></h4>
      <pre class="doc-declare"><code>OPERATE_RET get_wf_gw_nw_status(OUT GW_WIFI_NW_STAT_E *nw_stat);</code></pre>
      <pre class="doc-comment">/**
 * @brief Get device network state
 * 
 * @param[out] nw_stat Network state, see GW_WIFI_NW_STAT_E
 * 
 * @return OPRT_OK on success. Others on error, please refer to tuya_error_code.h
 */</pre>

      <h4 id="gw_wifi_modify_and_conn">Func <span>gw_wifi_modify_and_conn</span></h4>
      <pre class="doc-declare"><code>OPERATE_RET gw_wifi_modify_and_conn(IN CONST CHAR_T *ssid,IN CONST CHAR_T *passwd);</code></pre>
      <pre class="doc-comment">/**
 * @brief Connect Wi-Fi with given ssid and password
 * 
 * @param[in] ssid SSID to connect
 * @param[in] passwd Password of AP
 * 
 * @return OPRT_OK on success. Others on error, please refer to tuya_error_code.h
 */</pre>

      <h4 id="gw_get_ip">Func <span>gw_get_ip</span></h4>
      <pre class="doc-declare"><code>OPERATE_RET gw_get_ip(NW_IP_S *p_ip);</code></pre>
      <pre class="doc-comment">/**
 * @brief Get device IP
 * 
 * @param[out] p_ip Device IP, see NW_IP_S
 * 
 * @return OPRT_OK on success. Others on error, please refer to tuya_error_code.h
 */</pre>

      <h4 id="gw_get_mac">Func <span>gw_get_mac</span></h4>
      <pre class="doc-declare"><code>OPERATE_RET gw_get_mac(NW_MAC_S *p_mac);</code></pre>
      <pre class="doc-comment">/**
 * @brief Get device MAC
 * 
 * @param[out] p_mac Device MAC, see NW_MAC_S
 * 
 * @return OPRT_OK on success. Others on error, please refer to tuya_error_code.h
 */</pre>

      <h4 id="gw_get_rssi">Func <span>gw_get_rssi</span></h4>
      <pre class="doc-declare"><code>OPERATE_RET gw_get_rssi(SCHAR_T *p_rssi);</code></pre>
      <pre class="doc-comment">/**
 * @brief Get device RSSI level
 * 
 * @param[out] p_rssi Device RSSI level, if(*p_rssi == 99) then do't support get RSSI
 * 
 * @return OPRT_OK on success. Others on error, please refer to tuya_error_code.h
 */</pre>
      <h3 id="vars">Vars</h3>
      
      <h3 id="consts">Consts</h3>
      
      <h3 id="types">Types</h3>
      
      <h3 id="typedefs">Typedefs</h3>
      

      <h4 id="tuya_netlink_t;
">Typedef <span>tuya_netlink_t;
</span></h4>
      <pre class="doc-declare"><code>typedef struct {
   UINT_T resved;
}tuya_netlink_t;
</code></pre>
      <pre class="doc-comment"></pre>
    </div>
  </body>
</html>
            